/*-----------------------------------------------------------------------------------
Name: Hyuk Son
Date: Jul 22 2021
This do file does : 
	runs all the files in order
-----------------------------------------------------------------------------------*/
set more off
clear all
cap log close

/*--------------------------------------------------------- 
			 	Set up	 
---------------------------------------------------------*/	
*** working directories
gl cdir = "/Users/hyukhson/Dropbox/Malawi/Chimutu Education Project/17. Submission/Replication_package"

gl data_path = "$cdir/data"
gl raw_path = "$cdir/data/raw"
gl do_path = "$cdir/code"
gl log_path = "$cdir/log"
gl tex_path = "$cdir/output/tex"
gl present_path = "$cdir/output/presentation"
gl figure_path = "$cdir/output/figure"

cap mkdir "$cdir/output"
cap mkdir "$tex_path"
cap mkdir "$figure_path"
cap mkdir "$present_path"

*** System configuration
include "$do_path/config.do"

/*--------------------------------------------------------- 
			Data construction programs
---------------------------------------------------------*/	
do "$do_path/malawi_student_incentive_variable_generation.do"

/*--------------------------------------------------------- 
			Analysis programs
---------------------------------------------------------*/	
do "$do_path/malawi_student_incentive_table.do"
do "$do_path/malawi_student_incentive_graph.do"

/*--------------------------------------------------------- 
			close log files
---------------------------------------------------------*/	
local c_time_end = c(current_time)
di "Code started runing at `c_time'"
di "Code finished runing at `c_time_end'"
